home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / forthcmp.zip / STRINGS1.4TH < prev    next >
Text File  |  1992-03-30  |  1KB  |  42 lines

  1. \ STRING SUPPORT LIBRARY PART 1
  2. \ Contents Copyright (C) 1986 by Thomas Almy
  3.  
  4. \ Permission is granted to registered users of ForthCMP to sell or distribute
  5. \ computer programs incorporating the compiled contents of this file.
  6.  
  7. \ This file must be loaded BEFORE the application program.
  8. \ Then load STRINGS2.4TH before FORTHLIB.
  9.  
  10. \ When separate code and data segments are used, beware that
  11. \ string literals are in the code segment.  Use STR>DSEG
  12. \ to move to string buffer ( in DSEG ).
  13.  
  14.  
  15. .( Loading STRINGS ) CR
  16. 10 DECIMAL
  17. 1024 CONSTANT StringSize  \ alter if desired.
  18. DSEG
  19. CREATE strbufr  StringSize ALLOT
  20. \ you might also want to put strbufr at some arbitrary high constant
  21. \ location so that the size of the COM/EXE file is not increased:
  22. \ MaxAddress StringSize - 1000 - CONSTANT strbufr
  23.  
  24. strbufr EQU STRBUF
  25. strbufr EQU strend
  26.  
  27. 1 0 IN/OUT NEED +STRBUF
  28. 1 1 IN/OUT NEED STR>DSEG
  29. 2 0 IN/OUT NEED STRCPY
  30. 2 1 IN/OUT NEED STRPCK
  31. 1 1 IN/OUT NEED ASCIIZ
  32. 1 1 IN/OUT NEED -ASCIIZ
  33. 2 2 IN/OUT NEED -PATH
  34. 1 1 IN/OUT NEED -EXT
  35. 2 1 IN/OUT NEED +EXT
  36. 0 1 IN/OUT NEED argc
  37. 2 1 IN/OUT NEED -ASCIIZL
  38. 1 1 IN/OUT NEED argv
  39. 1 1 IN/OUT NEED getenv
  40.  
  41. 16 = #IF HEX #THEN
  42.